package han.chensing.latos.maker.windows.menus.negative.impl;

import han.chensing.latos.maker.V;
import han.chensing.latos.maker.windows.dialog.base.BasicDialog;
import han.chensing.latos.maker.windows.dialog.level.LevelEffectEditorDialog;
import han.chensing.latos.maker.windows.dialog.level.LevelLineEditorDialog;
import han.chensing.latos.maker.windows.menus.popup.RightClickMenu;

public class LevelNavigationMenu extends RightClickMenu.RightClickMenuList {
    public LevelNavigationMenu() {
        super();
        entries.add(new RightClickMenu.RightClickMenuItem("Line editor",() -> {
            if (V.project.getMusic() == null) {
                V.container.addWindow(new BasicDialog("Oops", "Select a music first"));
                return;
            }
            V.container.addWindow(new LevelLineEditorDialog());
        }));
        entries.add(new RightClickMenu.RightClickMenuItem("Effect editor",() -> {
            if (V.project.getMusic() == null) {
                V.container.addWindow(new BasicDialog("Oops", "Select a music first"));
                return;
            }
            V.container.addWindow(new LevelEffectEditorDialog());
        }));
        /*TODO entries.add(new ItemEntry("Configurations"){{
            listener=(event, x, y) -> V.container.addWindow(new ConfigManageDialog());
        }});*/
    }
}
